<template>
  <div class="main">
    <el-container class="content">
      <el-header class="header">八零教育</el-header>
      <el-container>

        <el-aside class="left">
          <!--  -->
          <el-row>
            <el-col
              :span="12"
              class="leftcont"
            >

              <el-menu
                :default-active="$route.path"
                router
                class="el-menu-vertical-demo"
                background-color="#545c64"
                text-color="#fff"
                active-text-color="#ffd04b"
              >

                <el-menu-item index="/main/classify">
                  <i class="el-icon-menu"></i>
                  <span slot="title">分类管理</span>
                </el-menu-item>

                <el-menu-item index="/main/user">
                  <i class="el-icon-s-custom"></i>
                  <span slot="title">用户管理</span>
                </el-menu-item>

                <el-menu-item index="/main/pl">
                  <i class="el-icon-edit"></i>
                  <span slot="title">评论管理</span>
                </el-menu-item>

                <el-menu-item index="/main/xiaoshou">
                  <i class="el-icon-s-flag"></i>
                  <span slot="title">销售管理</span>
                </el-menu-item>

                <el-menu-item index="/main/detail">
                  <i class="el-icon-more"></i>
                  <span slot="title">详情管理</span>
                </el-menu-item>

                <el-menu-item index="/main/buy">
                  <i class="el-icon-goods"></i>
                  <span slot="title">购物车</span>
                </el-menu-item>
                 <el-menu-item index="/main/peisong">
                  <i class="el-icon-goods"></i>
                  <span slot="title">配送</span>
                </el-menu-item>
              </el-menu>
            </el-col>
          </el-row>
          <!--  -->
        </el-aside>

        <el-container>

          <el-main>
            <router-view />
          </el-main>

          <el-footer class="footer"></el-footer>
        </el-container>

      </el-container>
    </el-container>
  </div>
</template>

<script>
export default {
  name: "Main",
  mounted() {
    console.log(this.$route.path);
  },
  data() {
    return {};
  }
};
</script>

<!-- Add "scoped" attribute to limit CSS to this component only -->
<style>
.header {
  background: #ccc;
  line-height: 60px;
  font-size: 25px;
  color: #ffeb3b;
}
.footer {
  background: #333;
}
.left {
  background-color: rgb(84, 92, 100);
}
.leftcont {
  width: 100%;
}
</style>
